//
//  CreatButton.m
//  wangyi
//
//  Created by dllo on 15/11/23.
//  Copyright (c) 2015年 liyinkai. All rights reserved.
//

#import "CreatButton.h"

@implementation CreatButton

+(UIButton *)CreatButton:(NSInteger)num withColor:(UIColor *)color withView:(UIView *)view withTitle:(NSString *)title {
    UIButton *button = [UIButton buttonWithType:UIButtonTypeSystem];
    button.frame = CGRectMake((view.bounds.size.width / 5) * num, 0, view.bounds.size.width / 5, 44);
    button.tintColor = (UIColor *)color;
    [button setTitle:title forState:UIControlStateNormal];
    button.titleLabel.font = [UIFont systemFontOfSize:15];
    button.tag = 100 + num;
    [view addSubview:button];
    return button;
}

@end
